# coding=utf-8
import arcpy


def cal_val(d_name):
    zNum = int(d_name.split('左'.decode('utf-8'))[1])
    yNum = int(d_name.split('右'.decode('utf-8'))[1])
    if '左'.decode('utf-8') in d_name:
        return zNum
    else:
        return yNum


row_count = 1
row_value = 0
def autoIncrement():
    global row_count, row_value
    if row_count % 2 != 0:
        row_value = row_value + 1
        row_count = row_count + 1
        return row_value
    elif row_count % 2 == 0:
        row_count = row_count + 1
        return row_value

row_count = 1
def cal_jo():
    global row_count
    row_count = row_count + 1
    if row_count % 2 == 0:
        return 1
    else:
        return 2

def conField(field_1):
    if (u'滑坡' in field_1):
        return '滑坡'
    elif (u'崩塌' in field_1):
        return '崩塌'
    elif (u'滑' in field_1):
        return '滑坡'
    elif (u'泥石流' in field_1):
        return '泥石流'
    elif (u'地面塌陷' in field_1):
        return '地面塌陷'
    else:
        return ''